#!/usr/sbin/rsct/perl5/bin/perl
# IBM_PROLOG_BEGIN_TAG 
# This is an automatically generated prolog. 
#  
#  
#  
# Licensed Materials - Property of IBM 
#  
# (C) COPYRIGHT International Business Machines Corp. 2000,2001 
# All Rights Reserved 
#  
# US Government Users Restricted Rights - Use, duplication or 
# disclosure restricted by GSA ADP Schedule Contract with IBM Corp. 
#  
# IBM_PROLOG_END_TAG 
#
# @(#)28   1.2         src/rsct/cfg_access/gpfs/ct_read_machines_lst.perl, cfg.access, rsct_rori, roris01a 1/24/01 09:41:25
#
# Usage: ct_read_machines_lst [-l] <filename>
#   -l for the local data access
#
use Getopt::Std;

my %opts = ();
&getopts(':l',\%opts);
my $mmref=(defined($opts{l}) ? "norefresh" : "refresh");
my $filename="";
# Get the arguments...
if ($#ARGV >= 0) {
    $filename = shift @ARGV;            # user specified resource
} else {
    print STDERR "#no file name\n";
    exit 1;
}

# return codes:
#   0 if successful
#   1 if there is an error
#   2 if <ct_read_machines.lst> not supported

$MMHA="/usr/lpp/mmfs/bin/mmha";
exec "${MMHA} haGetMachineslst $filename $mmref"; 
exit 1;
